import { request } from '@@/exports';

export function fetchAccount() {
  return request('/account', {
    method: 'GET',
  });
}


// 获取验证码图片
export async function getAccountCaptcha() {
  return request('/ygt/account/captcha', {
    method: 'GET',
    params: {}
  });
}


export function bindAccount( data: any ) {
  return request('/account', {
    method: 'POST',
    data,
  });
}


export function unBindAccount( data: any ) {
  return request('/account', {
    method: 'DELETE',
    data,
  });
}

export function updateAccount( data: any ) {
  return request('/account', {
    method: 'PUT',
    data,
  });
}
